$.ajax({
	url: 'index.php?a=all',
	dataType: 'json',
	success:function (data) {
		// alert(7);return;
		
		var div='';

		$.each(data,function(i) {
			var bgcolor = ['background:#D3D3D3','background:#E0FFFF','background:#FFA07A','background:#FF7F50','background:#FFE4B5','background:#F0E68C','background:#F08080','background:#DCDCDC','background:#FAEBD7','background:#B8860B'];
			// 取随机数
			var num = hd_random(0,9,true);
			// 随机top值
			// alert(78);
			var t = hd_random(50,600,true);
			var l = hd_random(20,800,true);
			var n = parseInt(i)+1;
			// alert(n);
				var time = data[i].time;
				var conturn = data[i].body;
				var name = data[i].title;
				var img = "<img src="+data[i].icon+"><img>";
				var style = bgcolor[num];

				var div ='<div class="listbox" onclick="top_up(this)" style='+style+';left:'+l+'px;top:'+t+'px;><div onclick="del(this)" class="xx">x</div><div class="tite"><p class="ncc">第[<span class="num">'+n+'</span>]条</p><p class="tt">时间：<span class="tm">'+time+'</span></p></div><p class="yw">愿望：</p><div class="neirong">'+conturn+'</div><div class="picc">'+img+'</div><div class="niceng">'+name+'</div></div>';
				// $('.wishes_box').append(div);
				$('.wishes_box').append(div);

	})
	}
})